﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Data.SqlClient;
using System.Linq;
using System.Linq.Expressions;
using OpenAuth.Repository.Domain;
using Infrastructure;


namespace OpenAuth.Repository.Interface
{
    /// <summary>
    /// 接口操作的仓储接口
    /// </summary>
    /// <typeparam name="T"></typeparam>
   public  interface IApiRepository<T> where T : class
    {
        /// <summary>
        /// 执行存储过程返回对象(查询)
        /// </summary>
        /// <param name="sql"></param>
        /// <returns></returns>
        IEnumerable<T> ExecuteTran<T>(string sql, List<SqlParameter> param) where T : class, new();
        /// <summary>
        /// 执行存储过程返回对象(写入)
        /// </summary>
        /// <typeparam name="T"></typeparam>
        /// <param name="sql"></param>
        /// <param name="param"></param>
        /// <returns></returns>
        DataTable PutTran(string sql, List<SqlParameter> param);
        /// <summary>
        /// 获取建行支付二维码内容
        /// </summary>
        /// <param name="patid">患者id</param>
        /// <param name="name">患者姓名</param>
        /// <param name="amount">充值金额</param>
        /// <returns></returns>
        //PaySecond GetQRText(string patid, string name,string phone,string card, float amount);
    }
}
